<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
    <title>Binding Test</title>
    <link rel="stylesheet" href="https://code.jquery.com/qunit/qunit-2.4.1.css">
</head>
<body>
    <div id="qunit"></div>
    <div id="qunit-fixture"></div>
    <script src="https://code.jquery.com/qunit/qunit-2.4.1.js"></script>

    <script type="text/javascript">
        (async () =>
        {
            await CefSharp.BindObjectAsync("boundAsync");

            QUnit.test("Async call (Divide 16 / 2):", function (assert)
            {
                var asyncCallback = assert.async();

                boundAsync.div(16, 2).then(function (actualResult)
                {
                    const expectedResult = 8

                    assert.equal(expectedResult, actualResult, "Divide 16 / 2 resulted in " + expectedResult);

                    asyncCallback();
                });
            });

        })();
    </script>

</body>
</html>
